#include "matrix.h"

typedef struct _t_roomcoplanarpolygon
{
	TRI< CVector > poly;
	_t_roomcoplanarpolygon* next;

} ROOMCOPLANAPOLYGON, *LPROOMCOPLANAPOLYGON, *PROOMCOPLANAPOLYGON;



typedef struct _t_roombspnodedata
{
	TRI<CVector> poly;
	PROOMCOPLANAPOLYGON coplanar;

	CPlane	plane;

	_t_roombspnodedata* front;
	_t_roombspnodedata* back;

	bool bIsLeaf;

} ROOMBSPNODEDATA, *LPROOMBSPNODEDATA,*PROOMBSPNODEDATA;



//--------------------------------------------------------------
//	a strip
//--------------------------------------------------------------
typedef struct
{
	u32		materialIndex;		//	index of the material to use
	u32		firstIndex;			//	first index in the strip
	u32		numIndices;			//	# of indices in the strip
	u16		firstVertex;		//	first vertex used in the strip
	u16		numVertices;		//	# of vertices used in the strip

} ROOMSTRIPDATA;

typedef struct
{
	u16				numRooms;

	ROOMSTRIPDATA	*roomStrips;
	ROOMBSPNODEDATA	*roomBspData;

} ROOMSDATA;
